﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Pages/CommonPages/MasterPageBackEnd.master" AutoEventWireup="true" CodeFile="StudentsHome.aspx.cs" Inherits="Pages_StudentPages_Students" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
    <div class="block">
                            <h2>Pesonal Info</h2>
                            <ul>
                                <li><i class="fa fa-angle-right"></i>Change Password</li>
                                <li><i class="fa fa-angle-right"></i>Update Info</li>
                            </ul>
                        </div>
                        <div class="block">
                            <h2>PAGE</h2>
                            
                            <ul id="content-box-tabs">
                                <li><i class="fa fa-angle-right"></i>Competition
                                    <ul class="managerOption">
                                        <li onclick="displayBlockStudent('StudentViewCompetition')"><i class="fa fa-angle-right"></i>View competition</li>                                        
                                    </ul>
                                </li>
                                <li><i class="fa fa-angle-right"></i>Design
                                    <ul class="managerOption">                                        
                                        <li onclick="displayBlockStudent('StudentViewDesign')"><i class="fa fa-angle-right"></i>View design</li>                            
                                    </ul>
                                </li>
                                <li><i class="fa fa-angle-right"></i>Awards
                                    <ul class="managerOption">
                                        <li onclick="displayBlockStudent('')"><i class="fa fa-angle-right"></i>View awards</li>                                        
                                    </ul>
                                </li>                                
                            </ul>
                        </div>                   

</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder2" Runat="Server">
<asp:ScriptManager ID="ScriptManager1" runat="server">
    </asp:ScriptManager>
    <br />
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <ContentTemplate>
        <!-- competitions -->
            <!-- view competitions -->    
        <div id="StudentViewCompetition">                    
                <h4>Competition List</h4>
                <asp:Label ID="Label3" runat="server" Text="Name of Competition: "></asp:Label>
                <asp:TextBox ID="txtSeachCompetition" runat="server" ></asp:TextBox>
                <asp:Button  ID="btnSeachCompetition" runat="server" Text="Search" 
                    onclick="btnSeachCompetition_Click"/>
                <asp:Button  ID="btnDisplayAllCompetition" runat="server" 
                    Text="Display All Competition" onclick="btnDisplayAllCompetition_Click" />
                <asp:GridView ID="grvCompetition" runat="server" AutoGenerateColumns="False" 
                                AllowPaging="True" DataKeyNames="comId" AllowSorting="True" 
                                PageSize="3" ForeColor="#FF9933" 
                                Width="679px" onrowdatabound="grvCompetition_RowDataBound" >
                     <Columns>
                         <asp:BoundField DataField="comId" HeaderText="Id">
                         <HeaderStyle ForeColor="Red" />
                         </asp:BoundField>
                         <asp:BoundField DataField="name" HeaderText="Name" >
                         <HeaderStyle ForeColor="Red" />
                         </asp:BoundField>
                         <asp:BoundField DataField="awards" HeaderText="Awards" >
                         <HeaderStyle ForeColor="Red" />
                         </asp:BoundField>
                         <asp:BoundField DataField="postDate" HeaderText="Post Date" 
                                        DataFormatString="{0:d}" >
                         <HeaderStyle ForeColor="Red" />
                         </asp:BoundField>
                         <asp:BoundField DataField="startDate" HeaderText="Start Date" 
                                        DataFormatString="{0:d}" >
                         <HeaderStyle ForeColor="Red" />
                         </asp:BoundField>
                         <asp:BoundField DataField="endDate" HeaderText="End Date" 
                                        DataFormatString="{0:d}" >
                         <HeaderStyle ForeColor="Red" />
                         </asp:BoundField>
                         <asp:BoundField DataField="description" HeaderText="Description" >
                         <HeaderStyle ForeColor="Red" />
                         </asp:BoundField>
                         <asp:BoundField DataField="quotation" HeaderText="Quotation" >
                         <HeaderStyle ForeColor="Red" />
                         </asp:BoundField>
                         <asp:BoundField DataField="userName" HeaderText="Manager" >
                         <HeaderStyle ForeColor="Red" />
                         </asp:BoundField>
                         <asp:BoundField DataField="NumberOfStaff" HeaderText="Number Of Staffs">
                         <HeaderStyle ForeColor="Red" />
                         </asp:BoundField>
                     </Columns>            
                </asp:GridView>
        </div>       
        <!--design-->
            <!--view design-->
        <div id="StudentViewDesign">                    
            <h4>Design</h4>
            <table>
                <tr>
                    <td><asp:Button  ID="Button2" runat="server" Text="Display All" 
                            onclick="Button2_Click"/></td>
                </tr>
                <tr>
                    <td><asp:Label ID="Label4" runat="server" Text="Name of Competition: "></asp:Label></td>
                    <td><asp:TextBox ID="TextBox1" runat="server" ></asp:TextBox></td>
                    <td><asp:Button  ID="Button1" runat="server" Text="Search Competition" 
                            onclick="Button1_Click"/></td>
                </tr>
                <tr>
                    <td><asp:Label ID="Label2" runat="server" Text="Name of Design: "></asp:Label></td>        
                    <td><asp:TextBox ID="txtSearchDesign" runat="server" ></asp:TextBox></td>
                    <td><asp:Button  ID="btnSearchDesign" runat="server" Text="Search Design" 
                            Width="172px" onclick="btnSearchDesign_Click"/></td>
                </tr>
            </table>
               <asp:GridView ID="grvDesign" runat="server" 
                                AllowSorting="True" AutoGenerateColumns="False"
                                PageSize="3" ForeColor="#FF9933" 
                                Width="685px" onrowdatabound="grvDesign_RowDataBound">
                      <Columns>
                           <asp:BoundField DataField="designId" HeaderText="Id">
                           <HeaderStyle ForeColor="Red" />
                           </asp:BoundField>
                           <asp:BoundField DataField="name" HeaderText="Name" >
                           <HeaderStyle ForeColor="Red" />
                           </asp:BoundField>
                           <asp:BoundField DataField="postDate" HeaderText="Post Date" >
                           <HeaderStyle ForeColor="Red" />
                           </asp:BoundField>
                           <asp:BoundField DataField="comName" HeaderText="Competition" >
                           <HeaderStyle ForeColor="Red" />
                           </asp:BoundField>
                      </Columns>
                 </asp:GridView>                                        
        </div>            
       
                </ContentTemplate>
    </asp:UpdatePanel>
</asp:Content>

